<?php
header("content-type:text/html;charset=utf-8");

require("connu.inc.php");

$tel = $_GET['id'];

$winnum = $_GET['id1'];



$select = "SELECT * FROM userinfo WHERE tel='$tel' AND winnum='$winnum'";

$result = mysql_query($select);


?>

<!DOCTYPE html>
<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>查询信息</title>
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <!-- Bootstrap -->
    <link rel="stylesheet" href="http://cdn.bootcss.com/twitter-bootstrap/3.0.3/css/bootstrap.min.css">
	<link rel="stylesheet" href="blogsystemcss.css">
    <!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
    <!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
    <!--[if lt IE 9]>
        <script src="http://cdn.bootcss.com/html5shiv/3.7.0/html5shiv.min.js"></script>
        <script src="http://cdn.bootcss.com/respond.js/1.3.0/respond.min.js"></script>
    <![endif]-->
	  <!-- jQuery (necessary for Bootstrap's JavaScript plugins) -->
    <script src="http://cdn.bootcss.com/jquery/1.10.2/jquery.min.js"></script>
    <!-- Include all compiled plugins (below), or include individual files as needed -->
    <script src="http://cdn.bootcss.com/twitter-bootstrap/3.0.3/js/bootstrap.min.js"></script>
	<style>
		.page-header
		{
		margin-top:0;
		background:#B0E0E6;
		}
		.col-1
		{
		background:#D6D6D6;
		}
		.checkbox
		{
		margin-left:20px;
		}
		h5
		{
		margin-top:30px;
		margin-bottom:0;
		}
	</style>
	</head>
  <body>
	<div class="container">
		<nav class="navbar navbar-default page-header">
			<!-- Brand and toggle get grouped for better mobile display -->
				<div class="navbar-header">
					<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1" aria-expanded="false">
						<span class="sr-only">Toggle navigation</span>
						<span class="icon-bar"></span>
						<span class="icon-bar"></span>
						<span class="icon-bar"></span>
					</button>
					<a class="navbar-brand" href="#"><b>大乐透代金券中奖查询</b></a>
				</div>

				<!-- Collect the nav links, forms, and other content for toggling -->
		</nav>
		<div class="row">
			<div class="col-md-2 col-sm-3">
				<nav class="navbar navbar-default col-1" id="sidebar-wrapper" role="navigation">
					<ul class="nav sidebar-nav">
						<li> <a href="slctel.html"> <i class="fa fa-fw fa-home"> </i><p align="center">查&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;询</p></a> </li>
					</ul>
				</nav>
			</div>
			<div class="col-md-10 col-sm-9">
				<form action="uploadinfo.php" method="post">
				<div>
				<table  class="table table-striped table-condensed">
				<tr>
					<th>&nbsp;&nbsp;&nbsp;&nbsp;</th>
					<th>id</th>
					<th>姓名</th>
					<th>电话</th>
					<th>中奖期数</th>
					<th>领取记录</th>
					<th>领取时间</th>
				</tr>
				<?php
					while($row = mysql_fetch_array($result))
					{
				?>
				<tr>
					<td><input type="checkbox" id="checkbox[]" name="checkbox[]" value="1"><input type="hidden" name="tel" value="<?php echo $row["tel"]?>"><input type="hidden" name="winnum" value="<?php echo $row["winnum"]?>"></td>
					<td><?php echo $row["id"]?></td>
					<td><?php echo $row["name"]?></a></td>
					<td><?php echo $row['tel']?></td>
					<td><?php echo $row["winnum"]?></td>
					<td><?php $w=$row["whether"];
							  if($w==1)
								  echo '<font style="color:#32CD32;">已领取</font>';
							  if($w==NULL)
								  echo '<font style="color:#CD0000;">未领取</font>';
					?></td>
					<td><?php if($row["recivetime"]!=NULL){echo date("Y-m-d H:i",$row["recivetime"]);}?></td>
					
				<?php
					}
					?>	
				</tr>
				</table>
				</div>
				
				<div class="form-group">
					<div class="col-sm-offset-2 col-sm-10">
						<button type="buttont"  onclick="javascript:window.location.href='slctel.html'" class="btn btn-default">返回</button>
						<button type="submit" id="button2" name="submit2" class="btn btn-default">领奖确认</button>
					</div>
				</div>
			</form>
			
			</div>
		</div>
	</div>
	<h5 align="center">技术支持 舜网（<a href="http://www.e23.cn">www.e23.cn</a>）
	</h5>
	


	<script>
		

	</script>

  </body>
</html>